package com.liy.spring.security.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;


@RestController
public class SimpleController {

    @GetMapping("/")
    public String first() {
        return "welcome to our system !";
    }

    @GetMapping("/home")
    public String home() {
        return "access /home success";
    }


    @GetMapping("/test")
    public String requiredLogin() {
        return "access  /test success";
    }


    @GetMapping("/login/success")
    public String loginSuccess() {
        return "congratulation, login success !";
    }


    @GetMapping("/login/failure")
    public String loginFailure() {
        return "Sorry login failed, username and password incorrect";
    }
}
